﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using Hallenberg.SmartClient.Menu;
using MenuDemo.Properties;

namespace MenuDemo.Controllers
{
    [HandleError]
    public class HomeController : Controller
    {
        [MenuItem(MenuDefinition.MainMenu, MenuDefinition.HomeIndex, "MenuHomeTitle")]
        public ActionResult Index()
        {
            this.ViewData["BrowserTitle"] = Properties.Resources.IndexBrowserTitle;
            this.ViewData["Header"] = Properties.Resources.IndexHeader;
            this.ViewData["Content"] = Properties.Resources.IndexText;

            return View();
        }

        [MenuItem(MenuDefinition.MainMenu, MenuDefinition.HomeAbout, "MenuAboutTitle", SortIndex = 300)]
        public ActionResult About()
        {
            this.ViewData["BrowserTitle"] = Properties.Resources.AboutBrowserTitle;
            this.ViewData["Header"] = Properties.Resources.AboutHeader;
            this.ViewData["Content"] = Properties.Resources.AboutText;

            return View();
        }
    }
}
